<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
a
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Online Case Management System Home Page</title>
<%@include file='common.jsp'%>
<script type="text/javascript">
	$(document).ready(function() {
		$('#testButton').bind('mouseover', function(){		
		alert($('#testSpan  a').text());			
		});
	

	});
	
	
	
</script>

</head>
<body>
	<table width="960px" align="center">
		<tr valign='top'>
			<td><%@include file='header.jsp'%></td>
		</tr>
		<tr>
		<td>
		<span id='testSpan'><a href="index.jsp">Click Here to Go to Home</a></span>
		<button id='testButton' name='testButton'  value='test button' ></button>
		</td>
		</tr>
		<tr>
			<td>
				<div class="headerDiv">Case Registration</div> <!-- Site navigation menu -->
				<!--  Change the links and the text as needed --> <%@include
					file="lmenu.jsp"%> <!-- Main content -->
				<form class="cmxform" id="CaseForm" method="post" action="newCase">
					<fieldset>
						<legend>Fill the form to submit new case</legend>

						<!--  Let us show errors here -->
						<div class="errorMessage" align="center">
							<%
								if (request.getAttribute("error") != null) {
									out.print(request.getAttribute("error"));
								}
							%>
						</div>
						<p>
							<label for="case_type_id">Case Type</label> <select
								name="case_type_id">
								<c:forEach items="${caseTypes}" var="caseType">
									<option value="${caseType.key}">${caseType.value}</option>
								</c:forEach>
							</select>
						</p>
						<p id='case_sub_type_para' style="display:none">
							<label for="case_sub_type_id">Case Sub Type</label> <select
								name="case_sub_type_id">
							</select>
						</p>

						<p>
							<label for="caseType">Help Category</label> <select
								name="help_type_id">
								<c:forEach items="${helpTypes}" var="helpType">
									<option value="${helpType.key}">${helpType.value}</option>
								</c:forEach>
							</select>
						</p>

						<p>
							<label for="summary">Summary of the case</label> <input
								id="summary" name="summary"
								value=<%=request.getParameter("summary") == null ? "''" : "'"
					+ request.getParameter("firstname") + "'"%> />
						</p>
						<p>
							<label for="description">Description</label>
							<textarea rows="5" cols="75" id="description" name="description"
								value=<%=request.getParameter("description") == null ? "''" : "'"
					+ request.getParameter("description") + "'"%>></textarea>

						</p>

						<p>
							<label for="needy_name">Needy name</label> <input id="needy_name"
								name="needy_name"
								value=<%=request.getParameter("needy_name") == null ? "''" : "'"
					+ request.getParameter("needy_name") + "'"%> />

						</p>

						<p>
							<label for="address">Address</label> <input id="address"
								name="address"
								value=<%=request.getParameter("address") == null ? "''" : "'"
					+ request.getParameter("address") + "'"%> />

						</p>

						<p>
							<label for="city">city</label> <input id="city" name="City"
								value=<%=request.getParameter("city") == null ? "''" : "'"
					+ request.getParameter("city") + "'"%> />

						</p>
						<p>
							<label for="state_id">State</label> <select name="state_id">
								<c:forEach items="${states}" var="option">
									<option value="${option.key}">${option.value}</option>
								</c:forEach>
							</select>
						</p>
						<p>
							<label for="postal_code">Postal Code</label> <input
								id="postal_code" name="postal_code"
								value=<%=request.getParameter("postal_code") == null ? "''" : "'"
					+ request.getParameter("postal_code") + "'"%> />

						</p>

						<p>
							<label for="contact_mobile">Mobile</label> <input
								id="contact_mobile" name="contact_mobile"
								value=<%=request.getParameter("contact_mobile") == null ? "''"
					: "'" + request.getParameter("contact_mobile") + "'"%> />

						</p>

						<p>
							<label for="contact_phone">Contact Phone</label> <input
								id="contact_phone" name="contact_phone"
								value=<%=request.getParameter("contact_phone") == null ? "''"
					: "'" + request.getParameter("contact_phone") + "'"%> />
						</p>
						<p>
							<label for="contact_email">Contact Email</label> <input
								id="contact_email" name="contact_email"
								value=<%=request.getParameter("contact_email") == null ? "''"
					: "'" + request.getParameter("contact_email") + "'"%> />
						</p>

						<p>
							<input class="submit" type="submit" value="Submit" />
						</p>


					</fieldset>

				</form>
			</td>

		</tr>

		<tr>
			<td><%@include file='footer.jsp'%></td>
		</tr>
	</table>
</body>
</html>
